package com.sls.game.dao.nutsnet.impl;

import org.springframework.stereotype.Repository;

import com.sls.game.dao.impl.SuperDAO;
import com.sls.game.dao.nutsnet.NutsNetGoodsDetailTopDAO;
import com.sls.game.pojo.nutsnet.NutsNetGoodsDetailTop;

@Repository("nutsNetGoodsDetailTopDAO")
public class NutsNetGoodsDetailTopDAOImpl extends
		SuperDAO<NutsNetGoodsDetailTop> implements NutsNetGoodsDetailTopDAO {

	/**
	 * 记录插入
	 * 
	 * @param info
	 */
	@Override
	public void insert(NutsNetGoodsDetailTop info) {
		this.getSqlSession().insert(
				"mybatis.xml.NutsNetGoodsDetailTopMapper.insert", info);
	}

	/**
	 * 根据商品编号，查询记录
	 * 
	 * @param goodsId
	 * @return
	 */
	@Override
	public NutsNetGoodsDetailTop queryInfo(String goodsId) {
		NutsNetGoodsDetailTop info = null;
		info = this.getSqlSession().selectOne(
				"mybatis.xml.NutsNetGoodsDetailTopMapper.queryInfo", goodsId);
		return info;
	}

	/**
	 * 记录更新
	 * 
	 * @param info
	 */
	@Override
	public void update(NutsNetGoodsDetailTop info) {
		this.getSqlSession().update(
				"mybatis.xml.NutsNetGoodsDetailTopMapper.update", info);

	}

}
